package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.ClientAddressMapper;
import com.ruoyi.system.domain.ClientAddress;
import com.ruoyi.system.service.IClientAddressService;

/**
 * 用户地址Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-09-24
 */
@Service
public class ClientAddressServiceImpl implements IClientAddressService 
{
    @Autowired
    private ClientAddressMapper clientAddressMapper;

    /**
     * 查询用户地址
     * 
     * @param addressId 用户地址主键
     * @return 用户地址
     */
    @Override
    public ClientAddress selectClientAddressByAddressId(Long addressId)
    {
        return clientAddressMapper.selectClientAddressByAddressId(addressId);
    }

    /**
     * 查询用户地址列表
     * 
     * @param clientAddress 用户地址
     * @return 用户地址
     */
    @Override
    public List<ClientAddress> selectClientAddressList(ClientAddress clientAddress)
    {
        return clientAddressMapper.selectClientAddressList(clientAddress);
    }

    /**
     * 新增用户地址
     * 
     * @param clientAddress 用户地址
     * @return 结果
     */
    @Override
    public int insertClientAddress(ClientAddress clientAddress)
    {
        return clientAddressMapper.insertClientAddress(clientAddress);
    }

    /**
     * 修改用户地址
     * 
     * @param clientAddress 用户地址
     * @return 结果
     */
    @Override
    public int updateClientAddress(ClientAddress clientAddress)
    {
        return clientAddressMapper.updateClientAddress(clientAddress);
    }

    /**
     * 批量删除用户地址
     * 
     * @param addressIds 需要删除的用户地址主键
     * @return 结果
     */
    @Override
    public int deleteClientAddressByAddressIds(Long[] addressIds)
    {
        return clientAddressMapper.deleteClientAddressByAddressIds(addressIds);
    }

    /**
     * 删除用户地址信息
     * 
     * @param addressId 用户地址主键
     * @return 结果
     */
    @Override
    public int deleteClientAddressByAddressId(Long addressId)
    {
        return clientAddressMapper.deleteClientAddressByAddressId(addressId);
    }
}
